package com.hx.nacosdemo;

/**
 * @author chm
 * @title: ProductDataServiceApplication
 * @projectName nacosdemo
 * @description: TODO
 * @date 2020/3/211:32
 */

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

@SpringBootApplication
public class ProductDataServiceApplication {
    public static void main(String[] args) {
        SpringApplication.run(ProductDataServiceApplication.class, args);
    }

    @RestController
    class EchoController {
        @RequestMapping(value = "/echo/{string}", method = RequestMethod.GET)
        public String echo(@PathVariable String string) {
            return "Hello Nacos Discovery " + string;
        }
    }
}